import axios from '@/libs/api.request'

// 第三方应用管理
export class ThirdPartyApplicationApi {
  // 根据条件获取第三方应用信息
  static getList (params) {
    return axios.request({
      url: '/ThirdPartyApplication/GetList',
      method: 'post',
      enctype: 'multipart/form-data',
      data: params
    })
  }

  // 根据ID获取第三方应用信息
  static getModel (params) {
    return axios.request({
      url: '/ThirdPartyApplication/GetModel',
      method: 'get',
      enctype: 'multipart/form-data',
      params: params
    })
  }

  // 保存第三方应用信息
  static save (params) {
    return axios.request({
      url: '/ThirdPartyApplication/Save',
      method: 'post',
      enctype: 'multipart/form-data',
      data: params
    })
  }

  // 启用/禁用第三方应用信息
  static batchEnabled (params) {
    return axios.request({
      url: '/ThirdPartyApplication/BatchEnabled',
      method: 'post',
      enctype: 'multipart/form-data',
      data: params
    })
  }

  // 删除第三方应用信息
  static delete (params) {
    return axios.request({
      url: '/ThirdPartyApplication/Delete',
      method: 'post',
      enctype: 'multipart/form-data',
      data: params
    })
  }
}
